//MAX-SAT SA problem-depended class
//$Id: maxsat_sa.h 140 2009-09-03 11:33:57Z Oleg.Bulychov $
#pragma once
#ifndef MAXSAT_SA_H
#define MAXSAT_SA_H

#include "../maxsat.h"

//__________________________________________________________________________________
class MaxSat_Solution_SA:
    public MaxSat_Solution
{
public:
    void move(double probability, uniform_random& rnd)
    {
        for (size_t i = 0; i < dim_; ++i)
        {
            if (rnd.next_Double() < probability)
            {
                data_[i] = !data_[i];
                changed_ = true;
            }
        }
    }
};
//__________________________________________________________________________________

#endif
//EOF!
